<!doctype html>
<html lang="en">
<head>
	<meta charset="utf-8">
	<title>jQuery UI Spinner - Default functionality</title>
	<link type="text/css" href="../../themes/base/jquery.ui.all.css" rel="stylesheet" />
	<script type="text/javascript" src="../../jquery-1.4.3.js"></script>
	<script type="text/javascript" src="../../external/jquery.mousewheel-3.0.4.js"></script>
	<script type="text/javascript" src="../../ui/jquery.ui.core.js"></script>
	<script type="text/javascript" src="../../ui/jquery.ui.widget.js"></script>
	<script type="text/javascript" src="../../ui/jquery.ui.button.js"></script>
	<script type="text/javascript" src="../../ui/jquery.ui.spinner.js"></script>
	<link type="text/css" href="../demos.css" rel="stylesheet" />
	<script type="text/javascript">
	$(function() {
		$("#spinner").spinner();
		
		$("#disable").toggle(function() {
			$("#spinner").spinner("disable");
		}, function() {
			$("#spinner").spinner("enable");
		});
		$("#destroy").toggle(function() {
			$("#spinner").spinner("destroy");
		}, function() {
			$("#spinner").spinner();
		});
		$("#getvalue").click(function() {
			alert($("#spinner").spinner("value"));
		});
		$("#setvalue").click(function() {
			$("#spinner").spinner("value", 5);
		});
		
		$("button").button();
	});
	</script>
</head>
<body>

<div class="demo">

<p><label for="spinner">Select a value:</label>
<input id="spinner" name="value" /></p>

<p>
<button id="disable">Toggle disable/enable</button>
<button id="destroy">Toggle widget</button>
</p>

<p>
<button id="getvalue">Get value</button>
<button id="setvalue">Set value to 5</button>
</p>

</div><!-- End demo -->

<div class="demo-description">
<p>
Default spinner.
</p>
</div><!-- End demo-description -->

</body>
</html>
